#include <cstdio>
#include <cstring>
#include <iostream>
const int N = 2020;
int p[N], c;
bool d[N << 1];
static int _ = [](int n = 2020) {
    memset(d, true, sizeof d);
    for (int i = 2; i <= n; ++ i) {
        if (d[i]) p[c ++] = i;
        for (int j = 0; i * p[j] <= n; ++ j) {
            d[i * p[j]] = false;
            if (i % p[j] == 0) break;
         }
    }
    return 0;
}();
int main() {
    printf("%d", 2020 - 1 - c);
    system("pause");
}